/*
------------------------------------------
    Rodeo Game Engine
    Rodeo Core Module
    ShadersManager.h - header file
    Copyright (c) Marcin Goryca
------------------------------------------
*/
#ifndef RODEO_CORE_SHADERSMANAGER_H_
#define RODEO_CORE_SHADERSMANAGER_H_

//#include <string>

#ifndef RODEO_RENDERER_CGSHADERS_H_
#include "renderer\cgshaders.h"
#endif

#ifndef RODEO_RENDERER_GL_GLSLSHADERS_H_
#include "renderer\gl\glslshaders.h"
#endif

namespace rodeocore
{
class ShadersManager
{
public: 
    ShadersManager()
    :shader_(nullptr)
    {}
    ~ShadersManager(){}

    // Creates Shaders
    // Parameter ShadersVendor - RODEO_CG, RODEO_GLSL
    // Parameter string filename of the vertex shader
    // Parameter string filename of the fragment shader
    // This method creates, loads and initializes Shaders,
    //    no further operations needed
    void create(ShadersVendor vendor, std::string vertex_shader, std::string fragment_shader);

    // Loads Shaders from files
    // Parameter string vertex_shader file name
    // Parameter string fragment_shader file name
    void load(std::string vertex_shader, std::string fragment_shader);

private:
    // Inits Shaders
    void init();
public: 
//==== MEMBERS ====//
    std::unique_ptr<rodeorenderer::ShadersInterface> shader_;
    std::unique_ptr<rodeorenderer::GLSLShaders >glsl_shader_;
    std::unique_ptr<rodeorenderer::CGShaders > cg_shader_;
};
}    // end of rodeocore namespace

#endif // RODEO_CORE_SHADERSMANAGER_H_